/**
 * 店铺相关API
 */

import {
	http,
	Method
} from '@/utils/request.js';
/**
 * 创建商品
 * @param params
 */
export function createGoods(params) {
	return http.request({
		url: '/api/MerchantManage.goods/create',
		method: Method.POST,
		data: params,
	});
}

/**
 * 查询商品列表
 * @param params
 */
export function storeGoodsList(params) {
	return http.request({
		url: '/api/MerchantManage.goods/list',
		method: Method.GET,
		params,
	});
}

/**
 * 获取商品详情
 * @param params
 */
export function storeGoodsDetails(params) {
	return http.request({
		url: '/api/MerchantManage.goods/detail',
		method: Method.GET,
		params,
	});
}


/**
 * 管理SKU数据
 * @param params
 */
export function manageSkuData(params) {
	return http.request({
		url: '/api/MerchantManage.goods/manageSkuData',
		method: Method.POST,
		data: params,
	});
}

/**
 * 修改商品
 * @param params
 */
export function goodsUpdate(params) {
	return http.request({
		url: '/api/MerchantManage.goods/update',
		method: Method.POST,
		data: params,
	});
}

/**
 * 订单列表
 * @param params
 */
export function getOrderList(params) {
	return http.request({
		url: '/api/MerchantManage.order/list',
		method: Method.GET,
		params,
	});
}

/**
 * 订单详情
 * @param params
 */
export function getOrderDetail(params) {
	return http.request({
		url: '/api/MerchantManage.order/detail',
		method: Method.GET,
		params,
	});
}